﻿using System;
using System.Windows;

namespace Moneyman.Library.Extensions
{
    public static class ApplicationExtension
    {
        public static T FindResource<T>(this Application app, object key)
        {
            try
            {
                return (T)app.Resources[key];
            }
            catch
            {
                throw new Exception();
            }
        }
    }
}
